﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="AdsEdit.aspx.cs" Inherits="FYPHP.AdsEdit" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="LeftContent" runat="server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="MainContent" runat="server">
    <table border="1" cellpadding="10" cellspacing="10" style="width: 722px; border-collapse: collapse; border-color: #aaaaaa;">
      
        <tr>
            <td colspan="2" style="font-size: 14px; text-align: center; background-color: #eee; color: #555555">
                <strong>Edit Advertisement</strong></td>
        </tr>

          <tr>
        <td>Picture</td>
        <td align="center">
            <img height="113px" width="480px" src="\uploads\ads\<% Response.Write(getPic()); %>" alt="" />
        </td>
        </tr>
        
            <tr>
        <td>ID</td>
        <td>
            <asp:Label ID="lblAID" runat="server"></asp:Label>
                </td>

        </tr>

        <tr>
            <td class="style1">
                Advertisement Link :</td>
            <td width="480px">
        http://<asp:TextBox ID="txtAdsLink" runat="server"></asp:TextBox>
                <span style="font-size:11px"><i>(Enter # if link does not present.)</i></span><asp:RequiredFieldValidator 
                    ID="RequiredFieldValidator2" runat="server" 
            ControlToValidate="txtAdsLink" ErrorMessage="*" ForeColor="Red"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td class="style1">
                Duration :</td>
            <td width="480px">
                <asp:TextBox ID="txtAdsDuration" runat="server"></asp:TextBox>
        &nbsp;<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" 
            ControlToValidate="txtAdsDuration" ErrorMessage="*" ForeColor="Red"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td valign="top" class="style1">
                Advertisement Image :</td>
            <td>
                <asp:FileUpload ID="AdsFileUpload1" runat="server" />
                <asp:Button id="UploadButton" Text="Upload file" OnClick="UploadButton_Click" runat="server">
                </asp:Button>
       &nbsp;<br />
                <asp:Label id="UploadStatusLabel" runat="server">
       </asp:Label>
                <asp:Label ID="imgName" runat="server"></asp:Label>
            </td>
        </tr>
        <tr>
            <td colspan="2" style="text-align: center; background-color: #eee;">
                <asp:Button ID="btnAdsEdit" runat="server" onclick="btnAdsEdit_Click" 
                    Text="Update" />
&nbsp;<asp:Button ID="btnCancel" runat="server" Text="Cancel" />
            </td>
        </tr>
    </table>
</asp:Content>
